#include <stdio.h>

int max(int x, int y)
{
	return x > y ? x : y;
}

int main(void)
{
	/* p 是函数指针 */
	int a1[10] = {0,1,2,3,4,5,6,7,8,9};
//    int (*p1)[10];
	int *p1;
	p1 = a1;
    for(int i=0;i<10;i++)
    {
//        printf("%d\n",*p1);
        printf("%d\n",p1[i]);
//        p1++;
    }
	int (* p)(int x, int y) = & max; // &可以省略
//    int (* p)(int, int) = & max; // &可以省略
	int a, b, c, d;
	printf("Please input 3 integers:");
	scanf("%d %d %d", & a, & b, & c);
	/* 与直接调用函数等价，d = max(max(a, b), c) */
	d = p(p(a, b), c);
	printf("The max number is: %d\n", d);
	return 0;
}


